package com.netease.c.a;

public abstract class a
{
  private byte[] a;
  private int b;
  private long c;

  protected a()
  {
    this.a = new byte[4];
    this.b = 0;
  }

  protected a(a parama)
  {
    this.a = new byte[parama.a.length];
    System.arraycopy(parama.a, 0, this.a, 0, parama.a.length);
    this.b = parama.b;
    this.c = parama.c;
  }

  public void a()
  {
    long l = this.c << 3;
    a(-128);
    while (this.b != 0)
      a(0);
    a(l);
    c();
  }

  public void a(byte paramByte)
  {
    byte[] arrayOfByte = this.a;
    int i = this.b;
    this.b = (i + 1);
    arrayOfByte[i] = paramByte;
    if (this.b == this.a.length)
    {
      a(this.a, 0);
      this.b = 0;
    }
    this.c = (1L + this.c);
  }

  protected abstract void a(long paramLong);

  protected abstract void a(byte[] paramArrayOfByte, int paramInt);

  public void a(byte[] paramArrayOfByte, int paramInt1, int paramInt2)
  {
    while ((this.b != 0) && (paramInt2 > 0))
    {
      a(paramArrayOfByte[paramInt1]);
      paramInt1++;
      paramInt2--;
    }
    while (paramInt2 > this.a.length)
    {
      a(paramArrayOfByte, paramInt1);
      paramInt1 += this.a.length;
      paramInt2 -= this.a.length;
      this.c += this.a.length;
    }
    while (paramInt2 > 0)
    {
      a(paramArrayOfByte[paramInt1]);
      paramInt1++;
      paramInt2--;
    }
  }

  public void b()
  {
    this.c = 0L;
    this.b = 0;
    for (int i = 0; i < this.a.length; i++)
      this.a[i] = 0;
  }

  protected abstract void c();
}

/* Location:           D:\android\hack\dex2jar-0.0.9.8\classes_dex2jar.jar
 * Qualified Name:     com.netease.c.a.a
 * JD-Core Version:    0.6.0
 */